Skip to content
This repository has been archived by the owner on Jul 20, 2022. It is now read-only.

Persist WP to disk to ensure it inherits hosts permissions #35

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kasparsd
Copy link
Contributor

Fixes #26.

  • Bind mount WP root to a local directory to ensure it inherits lower-level permissions of the host system instead of the default root used by named mounts.

Instead of named volumes that are always mounted as root
@derekherman
Copy link
Contributor

derekherman commented Dec 14, 2019

I'd prefer to remove all named volumes and create a data directory for this to live in like

- ./data/wordpress/html:/var/www/html

And also do this for mysql like

- ./data/mysql:/var/lib/mysql

The scripts for docker could be moved to /data/wordpress/config and /data/wordpress/Dockerfile. Then create a .gitignore inside the data directory with the following contents to allow for the data to be stored locally and have access to the filesystem.

*
!.gitignore
!wordpress/**
wordpress/html/*

And then update the build path build: ./data/wordpress

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fix media upload
2 participants